﻿using System;
using System.ComponentModel;
using System.Drawing;
using InkFx.WinControl.Core;
using InkFx.WinControl.Utils;

namespace InkFx.WinControl.Theme
{
    /// <summary>
    /// 
    /// </summary>
    [Theme("303", "XIDEPanel")]
    public class ThemeXIDEPanel : BaseTheme
    {
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEPanel_ForeColor = Color.Empty;
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEPanel_BackColor = Color.Empty;
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEPanel_BackColor_Active = Color.Empty;
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEPanel_BorderColor = Color.Empty;
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEPanel_BorderColor_Active = Color.Empty;
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEFloatForm_BackColor = SystemColors.Control;
        /// <summary>
        /// 内部字段
        /// </summary>
        protected Color m_XIDEFloatForm_BorderColor = SystemColors.Control;


        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEPanel_HeadTop_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEPanel_HeadTop_V4.png" }, 3, 0, 2, 2, FillStyle.Fill);
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEPanel_HeadBottom_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEPanel_HeadBottom_V4.png" }, 0, 3, 2, 2, FillStyle.Fill);
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEPanel_HeadLeft_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEPanel_HeadLeft_V4.png" }, 2, 2, 3, 0, FillStyle.Fill);
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEPanel_HeadRight_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEPanel_HeadRight_V4.png" }, 2, 2, 0, 3, FillStyle.Fill);


        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEGroup_Title_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEGroup_Title_V4.png" }, 3, 0, 2, 2, FillStyle.Fill);
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEGroup_HeadTop_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEGroup_HeadTop_V4.png" }, 3, 0, 2, 2, FillStyle.Fill);
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEGroup_HeadBottom_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEGroup_HeadBottom_V4.png" }, 0, 3, 2, 2, FillStyle.Fill);
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinImage_V6 m_XIDEGroup_Button_V6 = new SkinImage_V6 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEGroup_Button_V6.png" };
        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinBorderImage_V4 m_XIDEGroup_ButtonBack_V4 = new SkinBorderImage_V4(new SkinImage_V4 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDEGroup_ButtonBack_V4.png" }, 3, 3, 3, 3, FillStyle.Fill);


        /// <summary>
        /// 内部字段
        /// </summary>
        protected SkinImage_V10 m_XIDETipForm_Area_V10 = new SkinImage_V10 { Base64OrFile = @"Skin\ColorNormal\XIDEPanel\XIDETipForm_Area_V10.png" };




        /// <summary>
        /// 文本的颜色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("01 XIDEPanel_ForeColor"), Description("文本的颜色")]
        public virtual Color XIDEPanel_ForeColor
        {
            get { return m_XIDEPanel_ForeColor; }
            set { m_XIDEPanel_ForeColor = value; }
        }
        /// <summary>
        /// 基本背景色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("02 XIDEPanel_BackColor"), Description("基本背景色")]
        public virtual Color XIDEPanel_BackColor
        {
            get { return m_XIDEPanel_BackColor; }
            set { m_XIDEPanel_BackColor = value; }
        }
        /// <summary>
        /// 基本背景色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("03 XIDEPanel_BackColor_Active"), Description("基本背景色")]
        public virtual Color XIDEPanel_BackColor_Active
        {
            get { return m_XIDEPanel_BackColor_Active; }
            set { m_XIDEPanel_BackColor_Active = value; }
        }
        /// <summary>
        /// 外边框的颜色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("04 XIDEPanel_BorderColor"), Description("外边框的颜色")]
        public virtual Color XIDEPanel_BorderColor
        {
            get { return m_XIDEPanel_BorderColor; }
            set { m_XIDEPanel_BorderColor = value; }
        }
        /// <summary>
        /// 外边框的颜色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("05 XIDEPanel_BorderColor_Active"), Description("外边框的颜色")]
        public virtual Color XIDEPanel_BorderColor_Active
        {
            get { return m_XIDEPanel_BorderColor_Active; }
            set { m_XIDEPanel_BorderColor_Active = value; }
        }


        #region  XIDEPanel

        /// <summary>
        /// 选项卡为Top时, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("11 XIDEPanel_HeadTop_V4"), Description("选项卡为Top时, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEPanel_HeadTop_V4.png")]
        public virtual SkinBorderImage_V4 XIDEPanel_HeadTop_V4
        {
            get { return m_XIDEPanel_HeadTop_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEPanel_HeadTop_V4 = value;
            }
        }
        /// <summary>
        /// 选项卡为Bottom时, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("12 XIDEPanel_HeadBottom_V4"), Description("选项卡为Bottom时, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEPanel_HeadBottom_V4.png")]
        public virtual SkinBorderImage_V4 XIDEPanel_HeadBottom_V4
        {
            get { return m_XIDEPanel_HeadBottom_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEPanel_HeadBottom_V4 = value;
            }
        }
        /// <summary>
        /// 选项卡为Left时, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("13 XIDEPanel_HeadLeft_V4"), Description("选项卡为Left时, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEPanel_HeadLeft_V4.png")]
        public virtual SkinBorderImage_V4 XIDEPanel_HeadLeft_V4
        {
            get { return m_XIDEPanel_HeadLeft_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEPanel_HeadLeft_V4 = value;
            }
        }
        /// <summary>
        /// 选项卡为Right时, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("14 XIDEPanel_HeadRight_V4"), Description("选项卡为Right时, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEPanel_HeadRight_V4.png")]
        public virtual SkinBorderImage_V4 XIDEPanel_HeadRight_V4
        {
            get { return m_XIDEPanel_HeadRight_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEPanel_HeadRight_V4 = value;
            }
        }

        #endregion


        #region  XIDEGroup

        /// <summary>
        /// Group的选项卡标题栏, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("21 XIDEGroup_Title_V4"), Description("Group的选项卡标题栏, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEGroup_Title_V4.png")]
        public virtual SkinBorderImage_V4 XIDEGroup_Title_V4
        {
            get { return m_XIDEGroup_Title_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEGroup_Title_V4 = value;
            }
        }
        /// <summary>
        /// Group的选项卡为Top时, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("22 XIDEGroup_HeadTop_V4"), Description("Group的选项卡为Top时, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEGroup_HeadTop_V4.png")]
        public virtual SkinBorderImage_V4 XIDEGroup_HeadTop_V4
        {
            get { return m_XIDEGroup_HeadTop_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEGroup_HeadTop_V4 = value;
            }
        }
        /// <summary>
        /// Group的选项卡为Bottom时, 正常、悬浮、按下、禁用 4种状态 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("23 XIDEGroup_HeadBottom_V4"), Description("Group的选项卡为Bottom时, 正常、悬浮、按下、禁用 4种状态 贴图"), SkinImagePath(@"XIDEPanel\XIDEGroup_HeadBottom_V4.png")]
        public virtual SkinBorderImage_V4 XIDEGroup_HeadBottom_V4
        {
            get { return m_XIDEGroup_HeadBottom_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEGroup_HeadBottom_V4 = value;
            }
        }

        /// <summary>
        /// Group的按钮, 倒三角、展开、折叠、最大化、正常化、关闭 6种按钮 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("24 XIDEGroup_Button_V6"), Description("Group的按钮, 倒三角、展开、折叠、最大化、正常化、关闭 6种按钮 贴图"), SkinImagePath(@"XIDEPanel\XIDEGroup_Button_V6.png")]
        public virtual SkinImage_V6 XIDEGroup_Button_V6
        {
            get { return m_XIDEGroup_Button_V6; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinImage_V6);
                if (valType != null && valType != typeof(SkinImage_V6))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinImage_V6'", valType.Name));
                m_XIDEGroup_Button_V6 = value;
            }
        }
        /// <summary>
        /// Group的按钮背景, 正常、悬浮、按下、禁用 4种状态 背景贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("25 XIDEGroup_ButtonBack_V4"), Description("Group的按钮背景, 正常、悬浮、按下、禁用 4种状态 背景贴图"), SkinImagePath(@"XIDEPanel\XIDEGroup_ButtonBack_V4.png")]
        public virtual SkinBorderImage_V4 XIDEGroup_ButtonBack_V4
        {
            get { return m_XIDEGroup_ButtonBack_V4; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinBorderImage_V4);
                if (valType != null && valType != typeof(SkinBorderImage_V4))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinBorderImage_V4'", valType.Name));
                m_XIDEGroup_ButtonBack_V4 = value;
            }
        }

        #endregion


        #region  XIDEFloatForm

        /// <summary>
        /// 浮动窗体的 背景颜色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("31 XIDEFloatForm_BackColor"), Description("浮动窗体的 背景颜色")]
        public virtual Color XIDEFloatForm_BackColor
        {
            get { return m_XIDEFloatForm_BackColor; }
            set { m_XIDEFloatForm_BackColor = value; }
        }
        /// <summary>
        /// 浮动窗体的 边界颜色
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("32 XIDEFloatForm_BorderColor"), Description("浮动窗体的 边界颜色")]
        public virtual Color XIDEFloatForm_BorderColor
        {
            get { return m_XIDEFloatForm_BorderColor; }
            set { m_XIDEFloatForm_BorderColor = value; }
        }



        #endregion


        #region  XIDETipForm

        /// <summary>
        /// 浮动窗体拖拽时 的 提示区域, 中央、上、下、左、右 的 正常、悬浮 10种按钮 贴图
        /// </summary>
        [Category("303 XIDEPanel"), DisplayName("24 XIDETipForm_Area_V10"), Description("浮动窗体拖拽时 的 提示区域, 中央、上、下、左、右 的 正常、悬浮 10种按钮 贴图"), SkinImagePath(@"XIDEPanel\XIDETipForm_Area_V10.png")]
        public virtual SkinImage_V10 XIDETipForm_Area_V10
        {
            get { return m_XIDETipForm_Area_V10; }
            set
            {
                Type valType = value != null ? value.GetType() : typeof(SkinImage_V10);
                if (valType != null && valType != typeof(SkinImage_V10))
                    throw new Exception(string.Format("Can Not Parse Type From '{0}' To 'SkinImage_V10'", valType.Name));
                m_XIDETipForm_Area_V10 = value;
            }
        }


        #endregion



        /// <summary>
        /// 执行与释放或重置非托管资源相关的应用程序定义的任务。
        /// </summary>
        public override void Dispose()
        {
            base.Dispose();

            try { if (m_XIDEPanel_HeadTop_V4 != null) { m_XIDEPanel_HeadTop_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEPanel_HeadTop_V4 = null; }
            try { if (m_XIDEPanel_HeadBottom_V4 != null) { m_XIDEPanel_HeadBottom_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEPanel_HeadBottom_V4 = null; }
            try { if (m_XIDEPanel_HeadLeft_V4 != null) { m_XIDEPanel_HeadLeft_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEPanel_HeadLeft_V4 = null; }
            try { if (m_XIDEPanel_HeadRight_V4 != null) { m_XIDEPanel_HeadRight_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEPanel_HeadRight_V4 = null; }
            
            try { if (m_XIDEGroup_Title_V4 != null) { m_XIDEGroup_Title_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEGroup_Title_V4 = null; }
            try { if (m_XIDEGroup_HeadTop_V4 != null) { m_XIDEGroup_HeadTop_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEGroup_HeadTop_V4 = null; }
            try { if (m_XIDEGroup_HeadBottom_V4 != null) { m_XIDEGroup_HeadBottom_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEGroup_HeadBottom_V4 = null; }
            try { if (m_XIDEGroup_Button_V6 != null) { m_XIDEGroup_Button_V6.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEGroup_Button_V6 = null; }
            try { if (m_XIDEGroup_ButtonBack_V4 != null) { m_XIDEGroup_ButtonBack_V4.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDEGroup_ButtonBack_V4 = null; }
            
            try { if (m_XIDETipForm_Area_V10 != null) { m_XIDETipForm_Area_V10.Dispose(); } } catch (Exception ex) { Tools.LogWarn(ex); } finally { m_XIDETipForm_Area_V10 = null; }
        }
    }
}
